<script>
    document.onclick = function (ev) {
        ev = ev || window.event;
        console.log(ev);

        // 解构赋值
        // let {clientX:clientX1,clientY:clientY1} = ev;
        // console.log(clientX1,clientY1);

        let { clientX, clientY } = ev;
        console.log(clientX, clientY);
    }


    // 对象解构应用于函数传递参数
    function fn({ c, b, a }) {
        console.log(a, b, c);
    }

    fn({ a: 1, b: 2, c: 3 });

</script>